package at.fhhagenberg.mcm09.elevator.model;

public class InfoModel {
	
	private int isUpward;
	private boolean isDoorClosed;
	private float load;
	private float speed;
	private int pos;
	
	public int isUpward() {
		return isUpward;
	}
	public void setUpward(int _isUpward) {
		this.isUpward = _isUpward;
	}
	public boolean isDoorClosed() {
		return isDoorClosed;
	}
	public void setDoorClosed(boolean isDoorClosed) {
		this.isDoorClosed = isDoorClosed;
	}
	public float getLoad() {
		return load;
	}
	public void setLoad(float load) {
		this.load = load;
	}
	public float getSpeed() {
		return speed;
	}
	public void setSpeed(float speed) {
		this.speed = speed;
	}
	public boolean check(InfoModel info) {
		
		if(isUpward != info.isUpward()){
			return true;
		}
		if(isDoorClosed != info.isDoorClosed()){
			return true;
		}
		if(load != info.getLoad()){
			return true;
		}
		if(speed != info.getSpeed()){
			return true;
		}
		if(pos != info.getPos()){
			return true;
		}
		return false;
	}
	public void setPos(int pos) {
		this.pos = pos;
	}
	public int getPos() {
		return pos;
	}

}
